import { commonLs } from '../../utils/common';
import { TOGGLE_COLLAPSED_TYPE } from './type';

const actions = {
  toggleCollapsedAction: () => {
    const [err, collapsed] = commonLs.get('collapsed')
    commonLs.put('collapsed', err ? true : !collapsed)
    return { type: TOGGLE_COLLAPSED_TYPE }
  },
}

export default actions
